// 判断当前时间属于上午还是下午
export const getTime = () => {
    const now = new Date();
    const hour = now.getHours();
    let message = '';
    if (hour <= 9) {
        message = '早上好';
    } else if (hour > 9 && hour <= 11) {
        message = '上午好';
    } else if (hour > 11 && hour <= 13) {
        message = '中午好';
    } else if (hour > 13 && hour <= 18) {
        message = '下午好';
    } else {
        message = '晚上好';
    }
    return message;
};
